<template>
  <div id="app">
    <!-- <div id="nav">
      <router-link to="/">Home</router-link> |
      <router-link to="/play">Play</router-link>
    </div> -->
    <div class="history" @click="showHistory">
      
    </div>
    <div class="search" @click="search">
      <van-icon name="search" />
    </div>
    <router-view/>
  </div>
</template>
<script>
// @ is an alias to /src

export default {
  data: function() {
    return{
      src:''
    }
  },
  components: {
    routers(){
      return this.$router
    }
  },
  mounted() {
    console.log(window.location)
  },
  methods:{
    showHistory(){
      this.$router.push('/history')
    },
    search(){
      this.$router.push('/searchall')
    }
  }
};
</script>
<style lang="scss">
#app {
  font-family: "Avenir", Helvetica, Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  color: #2c3e50;
  height:100%;
  .history{
    position: fixed;
    bottom: 150px;
    right: 20px;
    width: 30px;
    height: 30px;
    font-size: 30px;
    text-align: center;
    cursor: pointer;
    border-radius: 50%;
    font-weight: 600;
    color: #000;
    line-height: 30px;
    background: url(./assets/history.png) no-repeat center center;
    background-size: 100%;
  }
  .search{
     position: fixed;
    bottom: 190px;
    right: 20px;
    width: 30px;
    height: 30px;
    font-size: 18px;
    text-align: center;
    cursor: pointer;
    border-radius: 50%;
    font-weight: 600;
    color: #fff;
    line-height: 30px;
    background: #000;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center
  }
}
#nav {
  padding: 30px;
  a {
    font-weight: bold;
    color: #2c3e50;
    &.router-link-exact-active {
      color: #42b983;
    }
  }
}
</style>
